<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('修改导演或演员个人信息')" />
    <th:block th:include="include :: datetimepicker-css" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-personinfo-edit" th:object="${dlPersonInfo}">
            <input name="id" th:field="*{id}" type="hidden">
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">人物名：</label>
                <div class="col-sm-8">
                    <input name="name" th:field="*{name}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">英文名：</label>
                <div class="col-sm-8">
                    <input name="enName" th:field="*{enName}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">是否导演：</label>
                <div class="col-sm-8">
                    <select name="isDirector" class="form-control m-b" th:with="type=${@dict.getType('dl_true_false')}" required>
                        <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{isDirector}"></option>
                    </select>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">是否演员：</label>
                <div class="col-sm-8">
                    <select name="isActor" class="form-control m-b" th:with="type=${@dict.getType('dl_true_false')}" required>
                        <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{isActor}"></option>
                    </select>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">粉丝数：</label>
                <div class="col-sm-8">
                    <input name="fans" th:field="*{fans}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">粉丝名称：</label>
                <div class="col-sm-8">
                    <input name="fansName" th:field="*{fansName}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">个人简介：</label>
                <div class="col-sm-8">
                    <input name="intruduce" th:field="*{intruduce}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">别名：</label>
                <div class="col-sm-8">
                    <input name="alias" th:field="*{alias}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">身高：</label>
                <div class="col-sm-8">
                    <input name="height" th:field="*{height}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">国籍：</label>
                <div class="col-sm-8">
                    <select name="country" class="form-control m-b" th:with="type=${@dict.getType('dl_country_type')}" required>
                        <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{country}"></option>
                    </select>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">血型：</label>
                <div class="col-sm-8">
                    <select name="bloodType" class="form-control m-b" th:with="type=${@dict.getType('dl_blood_type')}" required>
                        <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{bloodType}"></option>
                    </select>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">出生日期：</label>
                <div class="col-sm-8">
                    <div class="input-group date">
                        <input name="birthday" th:value="${#dates.format(dlPersonInfo.birthday, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text" required>
                        <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
                    </div>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">民族：</label>
                <div class="col-sm-8">
                    <select name="nation" class="form-control m-b" th:with="type=${@dict.getType('dl_nation_type')}" required>
                        <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{nation}"></option>
                    </select>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">出生地：</label>
                <div class="col-sm-8">
                    <input name="birthPlace" th:field="*{birthPlace}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">星座：</label>
                <div class="col-sm-8">
                    <select name="constellation" class="form-control m-b" th:with="type=${@dict.getType('dl_constellation_type')}" required>
                        <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{constellation}"></option>
                    </select>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">毕业学校：</label>
                <div class="col-sm-8">
                    <input name="school" th:field="*{school}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">性别：</label>
                <div class="col-sm-8">
                    <select name="gender" class="form-control m-b" th:with="type=${@dict.getType('dl_gender_type')}" required>
                        <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{gender}"></option>
                    </select>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">经纪公司：</label>
                <div class="col-sm-8">
                    <input name="company" th:field="*{company}" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">累计票房：</label>
                <div class="col-sm-8">
                    <input name="totalMovieProfit" th:field="*{totalMovieProfit}" class="form-control" type="text" required>
                </div>
            </div>
        </form>
    </div>
    <th:block th:include="include :: footer" />
    <th:block th:include="include :: datetimepicker-js" />
    <script th:inline="javascript">
        var prefix = ctx + "mydy/personinfo";
        $("#form-personinfo-edit").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/edit", $('#form-personinfo-edit').serialize());
            }
        }

        $("input[name='birthday']").datetimepicker({
            format: "yyyy-mm-dd",
            minView: "month",
            autoclose: true
        });
    </script>
</body>
</html>